[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4688: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3823)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4690: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3823)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4691: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3823)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4692: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3823)
Lasermad.com • View topic - Thermometer PIC code

Thermometer PIC code


Site Admin

Posts: 950

Joined: Tue Jul 24, 2012 8:05 pm

Post Wed Apr 17, 2013 2:57 pm

Thermometer PIC code

For anyone who wants to try tinkering with it, here is the ASM file for the PIC. Usual rules apply - you can do what you want with it as long as it's non-commercial.

Most of the code is safe to play with but don't modify the PWM settings unless you're measuring the current taken by the inverter and are prepared to switch off quick/replace the MOSFET.
As there was plenty of memory available it only uses loops where required, with much of it being linear and I hope easier to follow. Some of the comments will be out of date as things were tweaked later, or pasted from other sections and not modified. An example is the temperature smoothing, the comment still refers to *32 but one bit operation has been remmed out so it currently uses *16 as it settled faster and had little impact on the result.
.
.
.
Attachments
nixitherm piccode.zip
(10.37 KiB) Downloaded 1231 times

Posts: 4

Joined: Wed Apr 17, 2013 1:23 am

Post Sat Apr 20, 2013 8:45 pm

Re: Thermometer PIC code

Thanks for uploading the code!

I guess I will have to learn more about assembly language ( I'm more familiar with C).

What compiler are you using with this code?

Site Admin

Posts: 950

Joined: Tue Jul 24, 2012 8:05 pm

Post Sat Apr 20, 2013 9:32 pm

Re: Thermometer PIC code

Just the standard MPLAB IDE software with a PICKIT3.

Site Admin

Posts: 950

Joined: Tue Jul 24, 2012 8:05 pm

Post Wed Nov 05, 2014 2:12 am

Re: Thermometer PIC code

The code posted above is intended for a PIC16F1847 as originally used, the current kits use an 1827 and I've attached the latest version of the code for use with these. The only difference is the loaction of the saved display state has been fixed.
Attachments
1827 therm piccode.rar
(9.69 KiB) Downloaded 939 times

Site Admin

Posts: 950

Joined: Tue Jul 24, 2012 8:05 pm

Post Wed Aug 26, 2015 2:39 am

Re: Thermometer PIC code

The AM2302 sensor is a more accurate substitute for the DHT11 but the data is formatted slightly differently. This is a modified hexfile you can try out if you want to upgrade the current sensor(s) and improve the humidity accuracy.
Attachments
AM2302 sensor code mod.zip
(3.85 KiB) Downloaded 808 times

Site Admin

Posts: 950

Joined: Tue Jul 24, 2012 8:05 pm

Post Thu Aug 27, 2015 1:25 am

Re: Thermometer PIC code

And of course a version which should detect and process either a DHT11 or AM2303. The detection may or may not be 100% so consider it V0.1 ;)

(it depends on both LSBs of temp and humidity having a non-zero value)
Attachments
Dual sensor code mod.rar
(3.66 KiB) Downloaded 900 times

Posts: 4

Joined: Wed Apr 17, 2013 1:23 am

Post Thu Dec 17, 2015 5:26 am

Re: Thermometer PIC code

Hi,

I would like to try the dual sensor mod but my nixie thermometer have the pic16f1847. Can you upload an hex file for the pic16f1847.

Thank you!

Site Admin

Posts: 950

Joined: Tue Jul 24, 2012 8:05 pm

Post Sat Dec 19, 2015 5:07 am

Re: Thermometer PIC code

This should work:

2x IN-12 pod piccode.rar
(3.66 KiB) Downloaded 894 times

Posts: 4

Joined: Wed Apr 17, 2013 1:23 am

Post Tue Dec 22, 2015 4:53 pm

Re: Thermometer PIC code

Yes, it work great! I get more accurate values with am2302 sensor.

Thanks again.

Site Admin

Posts: 950

Joined: Tue Jul 24, 2012 8:05 pm

Post Sun Dec 11, 2016 3:12 am

Re: Thermometer PIC code

Just in case you can't compile the original .ASM file I've attached the final .hex to this post.
Attachments
Therm 1827 hexfile.rar
(3.53 KiB) Downloaded 493 times
Next

Return to Nixie thermometer V1

Who is online

Users browsing this forum: No registered users and 1 guest

cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by ST Software