help to manual sed sensor ID ..
-
Hi.
I'm totaly confused .. reload code to my sensor .. and eeprom is clear ..
now if start sensor then send request for new ID :
req node id
send: 255-255-0-0 s=255,c=3,t=3,pt=0,l=0,st=ok:
read: 255-1-0 s=255,c=3,t=3,pt=0,l=0:and in my serial gateway is respond:
0;0;3;0;9;read: 255-255-0 s=255,c=3,t=3,pt=0,l=0:255;255;3;0;3;how I can manulay send ID to sensor??
and sorry but what function have Inclusion button??
I don't know but on first time my sensor recieved ID from gateway.. why not now (again) ...
regards.
-
Hi. I tested node with Auto assign ID .. but my serial gateway don't send new ID to node ..
My node send data to gateway :
0;0;3;0;9;255;255;3;0;3;\n
and I know so node want new ID .. then to terminal I write this :
255;255;3;0;4;12\n
is this correct ?? or not ??
what is wrong ??regards..
PS: I use serial terminal from Arduino and in another serial prot terminal..
-
@dzairo I am having the same issue, but only with certain of my sensors.
Define:
int node_id = X; (X as the node id you have open to assign)and add
gw.begin(NULL, node_id);
-
yes .. I know this .. but I want AUTO assign ID from serial gateway ..
I don't want assign ID manually ..regards.
PS: how to define ACK .. serial gateway if send packet then want received back ACK that node packet received..
and how to check that node if send data to gateway , gateway got this data ..regards.
-
@dzairo
Cannot help you with sensors not auto assigning properly, as I have the same issue on a few of mine. I manually assigned them, and moved on.
-
hhmmmm... very interesting .. no other help.. only me and you have this problem..may be problem is with sketch .. must test another sketch..
must contact MySensors master for help... because if not work manual , then with controller will not working too..
regards
-
Are you sure there isn't any communication problem?
Here is a thread with exactly the same question:
http://forum.mysensors.org/topic/457/cannot-send-id/4
-
hi Hek .
I use node with 2xAA batteries with 47uF capacitor (tantalum ).. if power ON node then in gateway received all what node send . and if debugging node then see st=ok. then I mean that packet transmit OK . if remove batteries then node can send packet form capacitor many time with out of batteries . in serial gateway I test many type capacitors .. 1500uF 6,3V special with low ESR .. and sill now working .. I try all check again .. I try set different board with nRF24L01+ as receiver and try received packet from serial gateway.. and I will see ...hek what does't it mean if node debugging this : st=ok or st=fail ??
if configure one node as repeater .. can I see debugging from repeating too???regards.
-
It depends on what kind of sensor you want to use. If the sensor can operate down to 1.9V, then you don't need boosters, as both arduino (8Mhz version) and radio can operate down to that voltage level (or there abouts).
for a hint to a schematic, you could see this forum post
Also, if arduino is running directly off the battery, you can use a trick with measuring the internal vREF compared VCC, and then calculate the battery voltage from that (no external resistors needed to monitor battery voltage):
http://provideyourown.com/2012/secret-arduino-voltmeter-measure-battery-voltage/
-
@dzairo said:
hek what does't it mean if node debugging this : st=ok or st=fail ??
"st=fail" means that no ack was received after sending a package.
A repeating node prints debug messages as well.
-
hek thanks .. but st=ok it's mean so gateway received packet and is ACK packet to node
or only first device what receive packet from node answer ACK?what I mean.. node not see gateway only repeater .. send packet to repeater .. repeater send to gateway... and gateway answer ACK to repeater and repeater send to node ... or only repeater answer to node ACK ...but gateway not ...
sk=ok is mean that target device receive packet and answer ACK ?
I don't look to source code how it work..
sorry .. but there is not manual or more information how MySensors working..
because in packet is 4 argument = ACK .. my node send packet with ACK 0 then I don't know why gateway answer ACK .. .. this will be good explain ..if repeater debugging all air communication then must see command for request new node ID
regards.
-
"st=ok" is only inter-node ack by using the NRFs. hardware ack-feature.
The end-to-end ack is handled by MySensors library by sending a new message from the receiving node back to sender (when requested).
Please note that you should be in range of gateway when requesting id. There is a known bug when id-requests travels through repeaters (because of the use of 255 as temporary id which is also used for broadcasts). In the next version 254 will be used for as temp-id which should resolve this problem.
-
ehm...
then st=ok is only hardware ACK .. if node is connected directly to gateway then ACK is that gateway receive packet and respond ACK . but if node is connected to gateway trough repeater .. then repeater return hardware ACK ..but don't guarantee that gateway received packet..
OK.. understand this ..for request new node ID .. yes .. understand repeater make problems in topology scheme ..
I tested binary switch and binary switch sleep sketch .. then I will try another .. I will test it ..
but if send node request for new ID to network .. how many time wait for new packet ??? may be we have problem to answer for this request in correct time .. or??? I understand that binary switch sleep node go sleep .. but other not .. or ???
I understand this .. every time if node send any data to network and node ID is 255 (auto) then send request for new ID .. if ID is normal (not auto ) then send packet as code need..
for example : presentation .. if node id is auto then not send real presentation packet .. but send new ID request .. ...regards.
-
Hi all...
This is important for all ...
Hek I find problem with manual node ID setting ..Your code is optimized for ATmega328P 16Mhz - 115200 serial speed ..
and here is problem ... big problem !!
16MHz -115200 is in normal speed : 3.549% ERROR , and in double speed : 2.124% ERROR
with no calibrated 8Mhz internal RC oscilator is normal speed : 8.507% ERROR and in double speed : 3.549%then in fact .. no problem to send data from MCU to PC .. problem send data from PC to MCU ..
solution :
for sensor node or repeater .. we don't need received data from UART .. then can use 115200 with internal RC oscilator ..
for serial gateway is need to send and received data from to MCU with controller .. then use scrystal 16Mhz (as orginal code ) or use better crystall : 7.3728Mhz , 11.0592Mhz , 14.7456Mhz ... with this crystall is ERROR 0% ... or use lower speed for serial gateway for example 38400bps ...sorry for all .. but I'm not thinking about it .. and problem was all time in hardware ..
interesting is that if generate own bootloader for my node then first time I set 115200 bps speed and my software show error more then 8.5% ERROR ..and I must change speed to 38400 ...now it's working .. if node send request for new ID then I send it
regards.