Read data from MCP9808 #3526
Replies: 15 comments
-
Posted at 2020-10-11 by David1234321 another problem I have try to upload this code
I get no error while uploading ,
then nothing - the device is not replay I don't get any error - but it doesn't uplaod the code Thanks , |
Beta Was this translation helpful? Give feedback.
-
Posted at 2020-10-11 by @MaBecker The i2c address does not look correct, check the datasheet. |
Beta Was this translation helpful? Give feedback.
-
Posted at 2020-10-11 by Robin Sun 2020.10.11 Hi @david1234321 I see that you are running 2V07 but on what device? Please post > 'then nothing - the device is not replay' Will need to understand which device is under test. What are the contents of the var when entering the vaiable name Maybe try wrapping in sections, several lines of code within a try/catch block to possibly learn more about the error itself. > 'after reboot from power - It run the old code (the one on the first post)' Was |
Beta Was this translation helpful? Give feedback.
-
Posted at 2020-10-11 by @MaBecker Just did a double check, it is 0x18 plus base 0b000 so the address is ok. Please check wire and pin names. |
Beta Was this translation helpful? Give feedback.
-
Posted at 2020-10-12 by David1234321 the address is OK I think something is wrong with the flash memory this is the code:
I have used upload to RAM
now I have enter save() , in order to make it work after reboor\power off - everything this is what I have in the console after "save()"
what to do now ? something went wrong ? Thanks , |
Beta Was this translation helpful? Give feedback.
-
Posted at 2020-10-12 by @gfwilliams I think most likely what's happened is device hasn't been recognised - it looks like during the As you'd found with the MAX30102 chip, there could be some reasons why the device isn't discovered using I2C.
|
Beta Was this translation helpful? Give feedback.
-
Posted at 2020-10-12 by @gfwilliams Ok, just got your response - so ignore what I just wrote. You've hit this: http://www.espruino.com/Saving
All you need to do is choose to save to |
Beta Was this translation helpful? Give feedback.
-
Posted at 2020-10-12 by David1234321 so what to do now? I have reboot the device ,recoonet it
have try to run upload to FLASH
so what to do now? ** I have uplaod it now to RAM - and it's working (if it's help you to understand and help me) Thanks , |
Beta Was this translation helpful? Give feedback.
-
Posted at 2020-10-12 by @gfwilliams Try running Since RAM obviously works for you and you seem happy with that, try:
|
Beta Was this translation helpful? Give feedback.
-
Posted at 2020-10-12 by David1234321 2 questions:
*** update
Thanks , |
Beta Was this translation helpful? Give feedback.
-
Posted at 2020-10-12 by @gfwilliams
That's expected.
You don't need to, no. Just use the code I posted above. Read http://www.espruino.com/Saving
No - that was just because you were getting some strange errors and it ensures that everything is cleared out 'just in case'. |
Beta Was this translation helpful? Give feedback.
-
Posted at 2020-10-12 by David1234321 I don't know what to say: I have try to upload the code you posted(I'm write it so you will see no errors)
this is what I get :
both on RAM\Flash uplaod what is wrong now? update* |
Beta Was this translation helpful? Give feedback.
-
Posted at 2020-10-12 by @gfwilliams Do you have an internet connection on the computer? Modules are loaded from the internet so if your computer no longer has access to the net, it won't be able to load the module you've requested. |
Beta Was this translation helpful? Give feedback.
-
Posted at 2020-10-12 by David1234321 the computer is connected all the time to the internet
Thanks , |
Beta Was this translation helpful? Give feedback.
-
Posted at 2020-10-12 by David1234321 wellll I have try with another computer - and everything start to work what a waste of a day! so now its working and read the data every 10 seconds Thank you for the help! |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Posted at 2020-10-11 by David1234321
Hello ,
I have bought the MCP9808 and connect it
copy the code from here:
but I get this error:
what is missing?
do I need to download something?
Thanks,
Beta Was this translation helpful? Give feedback.
All reactions