Home
JAQForum Ver 20.06
Log In or Join  
Active Topics
Local Time 10:20 05 May 2024 Privacy Policy
Jump to

Notice. New forum software under development. It's going to miss a few functions and look a bit ugly for a while, but I'm working on it full time now as the old forum was too unstable. Couple days, all good. If you notice any issues, please contact me.

Forum Index : Microcontroller and PC projects : MM/MM+ 5.2/6.0?

     Page 7 of 7    
Author Message
Phil23
Guru

Joined: 27/03/2016
Location: Australia
Posts: 1664
Posted: 10:18am 07 May 2016
Copy link to clipboard 
Print this post

Hi Geoff,

Just a minor manual thing. page 90.

Maybe move this line out of the:-

"For users of earlier Versions box".




I skipped over the detail of the section a I considered myself not an earlier user, and tried to use arrays.

Cheers

Phil

 
Phil23
Guru

Joined: 27/03/2016
Location: Australia
Posts: 1664
Posted: 01:29pm 07 May 2016
Copy link to clipboard 
Print this post

  bigmik said   Hi Phil,

My IO Panel , as Cliff pointed out does just that.


Hi Mick,

I've had a few looks at your panel & price list.
I'm sure I could put one to use in one of my many thought.

Re the pricing, can you provide the board along with the complete set of components?

I am aware of the variation in postage cost, & have no problem with Satchel, Express, or whatever works for you.

Thanks

Phil.
 
bigmik

Guru

Joined: 20/06/2011
Location: Australia
Posts: 2870
Posted: 04:40pm 07 May 2016
Copy link to clipboard 
Print this post

Hi Phil,

I will PM you the details.

Mick
Mick's uMite Stuff can be found >>> HERE (Kindly hosted by Dontronics) <<<
 
Phil23
Guru

Joined: 27/03/2016
Location: Australia
Posts: 1664
Posted: 11:52am 12 May 2016
Copy link to clipboard 
Print this post

  robert.rozee said   given a simple mmbasic program is available to discover the serial number of a single sensor, it may be adequate to only expand the read command thus:

TEMPR START pin [, precision [, serialnum ]]
TEMPR( pin [, serialnum ])

it is then left up to the user to type in the program to discover the serial numbers of their sensors, note these down one by one, and enter them by hand into their final code.


Sorry to harp on this issue, but it keeps coming to mind in various potential projects from the physical wiring point of view.

Would I be correct to say that Temperature sensors, are the most likely devices to be used in multiples over a variety of control systems.

I read many posts about projects that involve multiple Temp inputs.

I like the look of Roberts suggested Syntax & presume actual serial#'s could be stored in an Array & passed to the Function.

Benefits would be two fold in freeing up I/O pins & simplifying installations.

Cheers
 
Geoffg

Guru

Joined: 06/06/2011
Location: Australia
Posts: 3165
Posted: 04:48pm 12 May 2016
Copy link to clipboard 
Print this post

Yes, this is becoming a regular subject in this thread.

It is really about intentions and priorities. When I first put the TEMPR() function in it was to give an inexperienced user a quick and accurate way to measure temperature. That's all.

But then a few were unhappy about waiting for the conversion time and someone wanted different precisions so I put in the TEMPR command (big mistake). Now we have searching for serial numbers and more. The problem is that it is getting more and more complicated and moving away from the intention of providing a quick and easy temperature measurement.

The other issue is that I doubt that many want to use multiple devices in strings. I can see that it is important to you Phil but it is not practical to develop complicated solutions for a single need. I try to be responsive to these things but in this case there are too many priorities that rank much higher.

The final point is that you can do everything that you need to do in BASIC - there is absolutely no need to integrate it into the interpreter. My thinking is that if you are sophisticated enough to dig into the data sheet to understand these requirements then you should be able to write the code to do what you want. Asking for the interpreter to do it just shifts the job to me.

Geoff
Geoff Graham - http://geoffg.net
 
Phil23
Guru

Joined: 27/03/2016
Location: Australia
Posts: 1664
Posted: 10:42am 18 May 2016
Copy link to clipboard 
Print this post

Thanks Geoff,

Appreciate you reply & agree with all the points you put forward.

With regards to your resources & priorities I totally agree.
Time poor here & on the learning curve, so as a newcomer it's easy to mistakenly see things like this as feature missing from the language, as opposed to something I can make it do.

I already have a few MicroMite Plus's here (Read 4), I'm yet to play with.
What's demonstrated in your video is very impressive & I'm looking forward to using it.
Best value for your resources is undoubtedly developing that platform.
Further videos would be great, even if short & candid.

You are correct, everything can be done in BASIC, the required 1-Wire commands are there; admittedly a challenge for a new comer, but now, with the help of others on here, I'm at the point where I've almost achieved the complete goal; making it simple to follow & and using minimal code.

What I now have:-
[Code]
DATA &H24,&H72,&H4A,&H07,&H00,&H00,&H1B 'Sensor1
DATA &HC9,&H5D,&H4B,&H07,&H00,&H00,&H60 'Sensor2
DATA &H46,&HB9,&H4A,&H07,&H00,&H00,&HE4 'Sensor3

'Load Serial#'s into Array
For I = 1 to TsNum 'sensor # count
For J = 1 to 7 'id byte count
Read Ts(J,I) 'read the data in the array
Next J
Next I
..
..
..
Function ReadTemp(TsNum As Integer) As Float

OneWire Reset PinTmp

'Read Sensor Using Serial Numbers from Array Data.
Ts1=Ts(1,TsNum):Ts2=Ts(2,TsNum):Ts3=Ts(3,TsNum):Ts4=Ts(4,TsNum):Ts5=Ts(5,TsNum):Ts6=Ts(6,TsNum):Ts7=Ts(7,TsNum)
OneWire Write PinTmp, 1, 10, &H55,&H28,Ts1,Ts2,Ts3,Ts4,Ts5,Ts6,Ts7,&H44

'Check sensor is ready
Timer=0 : Status=0
Do
If Timer > 1000 Then Error "Sensor Error"
OneWire Read PinTmp, 4, 1, Status ' Conversion status
Loop Until Status = 1

OneWire Write PinTmp, 1, 10, &H55,&H28,Ts1,Ts2,Ts3,Ts4,Ts5,Ts6,Ts7,&HBE
OneWire Read PinTmp, 2, 2, LTemp, HTemp

'Calculate the temp in C
ReadTemp=((HTemp And &b111) * 256 + LTemp) / 16
If HTemp And &b1000 Then ReadTemp=-ReadTemp ' adjust if negative

End Function
[/code]

It can probably be further improved, but it will do the job.

Searching for multiple Serial numbers on a bus is in one way desirable, but on the other hand, it's going to still require identifying which one is physically located where.

Extracting the serial numbers one at a time avoids this issue, and placing the numbers in a data table makes the code easy to follow.

Interesting things come out of Perth.

My other major project here, which has hardware functional involves the recovery of ceiling heat space to supplement our other heating as well balancing temperatures between certain rooms.

Duct fans & ducting, vents & multiple motorised damper valves & cabling in ceiling space now installed & being operating manually.
At the stage where the MicroMite can be integrated to manage the system.

This is a concept I've had in mind for many years & was further inspired by a Perth based company & their Murdock University study.

Huge amounts of thermal energy available for recovery.

A few interesting reads.

Kim Dartnall-The New Inventors
Murdock University Results
Using Hot Air

Cheers

Phil.Edited by Phil23 2016-05-19
 
kiiid

Guru

Joined: 11/05/2013
Location: United Kingdom
Posts: 671
Posted: 11:10pm 18 May 2016
Copy link to clipboard 
Print this post

Hi Geoff,
I wonder would it be very difficult for you to include something like OPTION STRICT which will require all variables and functions to have explicitly defined type "AS something"?


http://rittle.org

--------------
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 8592
Posted: 11:17pm 18 May 2016
Copy link to clipboard 
Print this post

  Quote  I wonder would it be very difficult for you to include something like OPTION STRICT which will require all variables and functions to have explicitly defined type "AS something"?


It is already there

[code]OPTION EXPLICIT
OPTION DEFAULT NONE[/code]

I set these up as a template "default.bt" in MMEDIT and then they are set every time you do a "NEW"Edited by matherp 2016-05-20
 
kiiid

Guru

Joined: 11/05/2013
Location: United Kingdom
Posts: 671
Posted: 11:57pm 18 May 2016
Copy link to clipboard 
Print this post

  matherp said  
  Quote  I wonder would it be very difficult for you to include something like OPTION STRICT which will require all variables and functions to have explicitly defined type "AS something"?


It is already there

[code]OPTION EXPLICIT
OPTION DEFAULT NONE[/code]

I set these up as a template "default.bt" in MMEDIT and then they are set every time you do a "NEW"


Ah, I didn't know that :)
Thank you!
http://rittle.org

--------------
 
Phil23
Guru

Joined: 27/03/2016
Location: Australia
Posts: 1664
Posted: 10:30am 21 May 2016
Copy link to clipboard 
Print this post

Just a suggestion for the file name of the manual available for download to include the suffix for the version number.

MicroMite Manual V5_2B1.pdf or similar.

Phil

 
CaptainBoing

Guru

Joined: 07/09/2016
Location: United Kingdom
Posts: 1985
Posted: 11:43pm 05 Jul 2017
Copy link to clipboard 
Print this post

deleted
Edited by CaptainBoing 2017-07-07
 
     Page 7 of 7    
Print this page


To reply to this topic, you need to log in.

© JAQ Software 2024