Updated modules to comply with __ ordering in rom tables.
This commit is contained in:
parent
93140a89a5
commit
dc27e9f7cf
|
@ -550,6 +550,8 @@ static int file_chdir( lua_State *L )
|
|||
#endif
|
||||
|
||||
LROT_BEGIN(file_obj, NULL, 0)
|
||||
LROT_FUNCENTRY( __gc, file_obj_free )
|
||||
LROT_TABENTRY ( __index, file_obj )
|
||||
LROT_FUNCENTRY( close, file_close )
|
||||
LROT_FUNCENTRY( read, file_read )
|
||||
LROT_FUNCENTRY( readline, file_readline )
|
||||
|
@ -557,8 +559,6 @@ LROT_BEGIN(file_obj, NULL, 0)
|
|||
LROT_FUNCENTRY( writeline, file_writeline )
|
||||
LROT_FUNCENTRY( seek, file_seek )
|
||||
LROT_FUNCENTRY( flush, file_flush )
|
||||
LROT_FUNCENTRY( __gc, file_obj_free )
|
||||
LROT_TABENTRY ( __index, file_obj )
|
||||
LROT_END(file_obj, NULL, 0)
|
||||
|
||||
// Module function map
|
||||
|
|
|
@ -791,6 +791,8 @@ LROT_BEGIN(http, NULL, 0)
|
|||
LROT_END(http, NULL, 0)
|
||||
|
||||
LROT_BEGIN(http_context, NULL, 0)
|
||||
LROT_FUNCENTRY(__gc, context_gc)
|
||||
LROT_TABENTRY (__index, http_context)
|
||||
LROT_FUNCENTRY(on, http_lapi_on)
|
||||
LROT_FUNCENTRY(request, http_lapi_request)
|
||||
LROT_FUNCENTRY(setmethod, http_lapi_setmethod)
|
||||
|
@ -799,8 +801,6 @@ LROT_BEGIN(http_context, NULL, 0)
|
|||
LROT_FUNCENTRY(setpostdata, http_lapi_setpostdata)
|
||||
LROT_FUNCENTRY(close, context_close)
|
||||
LROT_FUNCENTRY(ack, http_lapi_ack)
|
||||
LROT_FUNCENTRY(__gc, context_gc)
|
||||
LROT_TABENTRY (__index, http_context)
|
||||
LROT_END(http_context, NULL, 0)
|
||||
|
||||
static int luaopen_http(lua_State *L)
|
||||
|
|
|
@ -636,6 +636,8 @@ static int mqtt_new(lua_State* L) {
|
|||
|
||||
// map client methods to functions:
|
||||
LROT_BEGIN(mqtt_metatable, NULL, 0)
|
||||
LROT_FUNCENTRY(__gc, mqtt_delete)
|
||||
LROT_TABENTRY(__index, mqtt_metatable)
|
||||
LROT_FUNCENTRY(connect, mqtt_connect)
|
||||
LROT_FUNCENTRY(close, mqtt_close)
|
||||
LROT_FUNCENTRY(lwt, mqtt_lwt)
|
||||
|
@ -643,8 +645,6 @@ LROT_BEGIN(mqtt_metatable, NULL, 0)
|
|||
LROT_FUNCENTRY(subscribe, mqtt_subscribe)
|
||||
LROT_FUNCENTRY(unsubscribe, mqtt_unsubscribe)
|
||||
LROT_FUNCENTRY(on, mqtt_on)
|
||||
LROT_FUNCENTRY(__gc, mqtt_delete)
|
||||
LROT_TABENTRY(__index, mqtt_metatable)
|
||||
LROT_END(mqtt_metatable, NULL, 0)
|
||||
|
||||
// Module function map
|
||||
|
|
|
@ -1109,14 +1109,16 @@ static void lerr_cb (lua_State *L, lnet_userdata *ud, err_t err)
|
|||
|
||||
// Module function map
|
||||
LROT_BEGIN(net_tcpserver, NULL, 0)
|
||||
LROT_FUNCENTRY( __gc, net_delete )
|
||||
LROT_TABENTRY ( __index, net_tcpserver )
|
||||
LROT_FUNCENTRY( listen, net_listen )
|
||||
LROT_FUNCENTRY( getaddr, net_getaddr )
|
||||
LROT_FUNCENTRY( close, net_close )
|
||||
LROT_FUNCENTRY( __gc, net_delete )
|
||||
LROT_TABENTRY ( __index, net_tcpserver )
|
||||
LROT_END(net_tcpserver, NULL, 0)
|
||||
|
||||
LROT_BEGIN(net_tcpsocket, NULL, 0)
|
||||
LROT_FUNCENTRY( __gc, net_delete )
|
||||
LROT_TABENTRY ( __index, net_tcpsocket )
|
||||
LROT_FUNCENTRY( connect, net_connect )
|
||||
LROT_FUNCENTRY( close, net_close )
|
||||
LROT_FUNCENTRY( on, net_on )
|
||||
|
@ -1124,19 +1126,17 @@ LROT_BEGIN(net_tcpsocket, NULL, 0)
|
|||
LROT_FUNCENTRY( dns, net_dns )
|
||||
LROT_FUNCENTRY( getpeer, net_getpeer )
|
||||
LROT_FUNCENTRY( getaddr, net_getaddr )
|
||||
LROT_FUNCENTRY( __gc, net_delete )
|
||||
LROT_TABENTRY ( __index, net_tcpsocket )
|
||||
LROT_END(net_tcpsocket, NULL, 0)
|
||||
|
||||
LROT_BEGIN(net_udpsocket, NULL, 0)
|
||||
LROT_FUNCENTRY( __gc, net_delete )
|
||||
LROT_TABENTRY ( __index, net_udpsocket )
|
||||
LROT_FUNCENTRY( listen, net_listen )
|
||||
LROT_FUNCENTRY( close, net_close )
|
||||
LROT_FUNCENTRY( on, net_on )
|
||||
LROT_FUNCENTRY( send, net_send )
|
||||
LROT_FUNCENTRY( dns, net_dns )
|
||||
LROT_FUNCENTRY( getaddr, net_getaddr )
|
||||
LROT_FUNCENTRY( __gc, net_delete )
|
||||
LROT_TABENTRY ( __index, net_udpsocket )
|
||||
LROT_END(net_udpsocket, NULL, 0)
|
||||
|
||||
LROT_BEGIN(net_dns, NULL, 0)
|
||||
|
@ -1146,6 +1146,7 @@ LROT_BEGIN(net_dns, NULL, 0)
|
|||
LROT_END(net_dns, NULL, 0)
|
||||
|
||||
LROT_BEGIN(net, NULL, 0)
|
||||
LROT_TABENTRY ( __metatable, net )
|
||||
LROT_FUNCENTRY( createServer, net_createServer )
|
||||
LROT_FUNCENTRY( createConnection, net_createConnection )
|
||||
LROT_FUNCENTRY( createUDPSocket, net_createUDPSocket )
|
||||
|
@ -1154,7 +1155,6 @@ LROT_BEGIN(net, NULL, 0)
|
|||
LROT_TABENTRY ( dns, net_dns )
|
||||
LROT_NUMENTRY ( TCP, TYPE_TCP )
|
||||
LROT_NUMENTRY ( UDP, TYPE_UDP )
|
||||
LROT_TABENTRY ( __metatable, net )
|
||||
LROT_END(net, NULL, 0)
|
||||
|
||||
int luaopen_net( lua_State *L ) {
|
||||
|
|
|
@ -679,6 +679,9 @@ static int pulsecnt_unregister(lua_State* L){
|
|||
}
|
||||
|
||||
LROT_BEGIN(pulsecnt_dyn, NULL, 0)
|
||||
LROT_FUNCENTRY( __gc, pulsecnt_unregister )
|
||||
LROT_TABENTRY ( __index, pulsecnt_dyn )
|
||||
// LROT_FUNCENTRY( __tostring, pulsecnt_tostring )
|
||||
LROT_FUNCENTRY( getCnt, pulsecnt_getCnt )
|
||||
LROT_FUNCENTRY( clear, pulsecnt_clear )
|
||||
LROT_FUNCENTRY( testCb, pulsecnt_testCb )
|
||||
|
@ -690,10 +693,6 @@ LROT_BEGIN(pulsecnt_dyn, NULL, 0)
|
|||
LROT_FUNCENTRY( setFilter, pulsecnt_set_filter )
|
||||
LROT_FUNCENTRY( rawSetEventVal, pulsecnt_set_event_value )
|
||||
LROT_FUNCENTRY( rawGetEventVal, pulsecnt_get_event_value )
|
||||
|
||||
// LROT_FUNCENTRY( __tostring, pulsecnt_tostring )
|
||||
LROT_FUNCENTRY( __gc, pulsecnt_unregister )
|
||||
LROT_TABENTRY ( __index, pulsecnt_dyn )
|
||||
LROT_END(pulsecnt_dyn, NULL, 0)
|
||||
|
||||
LROT_BEGIN(pulsecnt, NULL, 0)
|
||||
|
|
|
@ -328,12 +328,12 @@ static int lsdmmc_umount( lua_State *L )
|
|||
}
|
||||
|
||||
LROT_BEGIN(sdmmc_card, NULL, 0)
|
||||
LROT_TABENTRY( __index, sdmmc_card )
|
||||
LROT_FUNCENTRY( read, lsdmmc_read )
|
||||
LROT_FUNCENTRY( write, lsdmmc_write )
|
||||
LROT_FUNCENTRY( get_info, lsdmmc_get_info )
|
||||
LROT_FUNCENTRY( mount, lsdmmc_mount )
|
||||
LROT_FUNCENTRY( umount, lsdmmc_umount )
|
||||
LROT_TABENTRY( __index, sdmmc_card )
|
||||
LROT_END(sdmmc_card, NULL, 0)
|
||||
|
||||
LROT_BEGIN(sdmmc, NULL, 0)
|
||||
|
|
|
@ -178,10 +178,10 @@ free_mem:
|
|||
|
||||
|
||||
LROT_BEGIN(lspi_device, NULL, 0)
|
||||
LROT_FUNCENTRY( transfer, lspi_device_transfer )
|
||||
LROT_FUNCENTRY( remove, lspi_device_free )
|
||||
LROT_FUNCENTRY( __gc, lspi_device_free )
|
||||
LROT_TABENTRY( __index, lspi_device )
|
||||
LROT_FUNCENTRY( transfer, lspi_device_transfer )
|
||||
LROT_FUNCENTRY( remove, lspi_device_free )
|
||||
LROT_END(lspi_device, NULL, 0)
|
||||
|
||||
|
||||
|
@ -321,10 +321,10 @@ static int lspi_host_device( lua_State *L )
|
|||
|
||||
|
||||
LROT_BEGIN(lspi_master, NULL, 0)
|
||||
LROT_FUNCENTRY( device, lspi_host_device )
|
||||
LROT_FUNCENTRY( close, lspi_host_free )
|
||||
LROT_FUNCENTRY( __gc, lspi_host_free )
|
||||
LROT_TABENTRY( __index, lspi_master )
|
||||
LROT_FUNCENTRY( device, lspi_host_device )
|
||||
LROT_FUNCENTRY( close, lspi_host_free )
|
||||
LROT_END(lspi_master, NULL, 0)
|
||||
|
||||
|
||||
|
|
|
@ -236,6 +236,8 @@ static int tmr_create( lua_State *L ) {
|
|||
// Module function map
|
||||
|
||||
LROT_BEGIN(tmr_dyn, NULL, 0)
|
||||
LROT_FUNCENTRY( __gc, tmr_unregister )
|
||||
LROT_TABENTRY ( __index, tmr_dyn )
|
||||
LROT_FUNCENTRY( register, tmr_register )
|
||||
LROT_FUNCENTRY( alarm, tmr_alarm )
|
||||
LROT_FUNCENTRY( start, tmr_start )
|
||||
|
@ -243,8 +245,6 @@ LROT_BEGIN(tmr_dyn, NULL, 0)
|
|||
LROT_FUNCENTRY( unregister, tmr_unregister )
|
||||
LROT_FUNCENTRY( interval, tmr_interval)
|
||||
LROT_FUNCENTRY( state, tmr_state )
|
||||
LROT_FUNCENTRY( __gc, tmr_unregister )
|
||||
LROT_TABENTRY ( __index, tmr_dyn )
|
||||
LROT_END(tmr_dyn, NULL, 0)
|
||||
|
||||
LROT_BEGIN(tmr, NULL, 0)
|
||||
|
|
|
@ -590,15 +590,14 @@ static int touch_unregister(lua_State* L) {
|
|||
}
|
||||
|
||||
LROT_BEGIN(touch_dyn, NULL, 0)
|
||||
LROT_FUNCENTRY( __gc, touch_unregister )
|
||||
LROT_TABENTRY ( __index, touch_dyn )
|
||||
// LROT_FUNCENTRY( __tostring, touch_tostring )
|
||||
LROT_FUNCENTRY( read, touch_read )
|
||||
LROT_FUNCENTRY( intrEnable, touch_intrEnable )
|
||||
LROT_FUNCENTRY( intrDisable, touch_intrDisable )
|
||||
LROT_FUNCENTRY( setThres, touch_setThres )
|
||||
LROT_FUNCENTRY( setTriggerMode, touch_setTriggerMode )
|
||||
|
||||
// LROT_FUNCENTRY( __tostring, touch_tostring )
|
||||
LROT_FUNCENTRY( __gc, touch_unregister )
|
||||
LROT_TABENTRY ( __index, touch_dyn )
|
||||
LROT_END(touch_dyn, NULL, 0)
|
||||
|
||||
LROT_BEGIN(touch, NULL, 0)
|
||||
|
|
|
@ -559,6 +559,8 @@ static int lu8g2_updateDisplayArea( lua_State *L )
|
|||
|
||||
|
||||
LROT_BEGIN(lu8g2_display, NULL, 0)
|
||||
//LROT_FUNCENTRY( __gc, lu8g2_display_free )
|
||||
LROT_TABENTRY( __index, lu8g2_display )
|
||||
LROT_FUNCENTRY( clearBuffer, lu8g2_clearBuffer )
|
||||
LROT_FUNCENTRY( drawBox, lu8g2_drawBox )
|
||||
LROT_FUNCENTRY( drawCircle, lu8g2_drawCircle )
|
||||
|
@ -600,8 +602,6 @@ LROT_BEGIN(lu8g2_display, NULL, 0)
|
|||
LROT_FUNCENTRY( setPowerSave, lu8g2_setPowerSave )
|
||||
LROT_FUNCENTRY( updateDispla, lu8g2_updateDisplay )
|
||||
LROT_FUNCENTRY( updateDisplayArea, lu8g2_updateDisplayArea )
|
||||
//LROT_FUNCENTRY( __gc, lu8g2_display_free )
|
||||
LROT_TABENTRY( __index, lu8g2_display )
|
||||
LROT_END(lu8g2_display, NULL, 0)
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue