Date   
Re: Finding variables in source code

Clark Martin
 

I use TextWrangler on my Macs.  It has a very capable search function including grep capability.  I use it for most of my code development.


Clark Martin
KK6ISP

On Jul 16, 2018, at 2:21 PM, Arv Evans <arvid.evans@...> wrote:

The Arduino IDE, and most other IDEs include "find" and "find next"  in the edit commands.
This is very similar to the now ancient UNIX grep, fgrep, etc that eventually made its way into 
several DOS editors.  Linux has continued the grep legacy in original and several new forms.
Not sure but I would think that Apple's OSX would also include the function as it was there in 
original BSD UNIX.  It is also present in the shell programming tool for my Linux based 
Android cell phone.

Re: 3.2in Nextion display now looks great.

VK3SQ - Geoff <vk3sq@...>
 

Hi Malcolm, that screen and case looks fantastic..you've  done a great job. 73 de Geoff vk3sq

Re: Finding variables in source code

Clark Martin
 

I should add, it has a multi-file search capability which is excellent for searching source code for definitions, declarations, etc.

Clark Martin
KK6ISP

On Jul 16, 2018, at 2:47 PM, Clark Martin <kk6isp@...> wrote:

I use TextWrangler on my Macs. It has a very capable search function including grep capability. I use it for most of my code development.

New file uploaded to BITX20@groups.io

BITX20@groups.io Notification <BITX20+notification@...>
 

Hello,

This email message is a notification to let you know that a file has been uploaded to the Files area of the BITX20@groups.io group.

File: ubitx_35B7.HMI

Uploaded By: Allen Merrell

Description:

You can access this file at the URL:
https://groups.io/g/BITX20/files/3.2%20&%203.5%20for%20Nextion%20and%20CEC%201.095/ubitx_35B7.HMI

Cheers,
The Groups.io Team

New file uploaded to BITX20@groups.io

BITX20@groups.io Notification <BITX20+notification@...>
 

Hello,

This email message is a notification to let you know that a file has been uploaded to the Files area of the BITX20@groups.io group.

File: ubitx_35B7.tft

Uploaded By: Allen Merrell

Description:

You can access this file at the URL:
https://groups.io/g/BITX20/files/3.2%20&%203.5%20for%20Nextion%20and%20CEC%201.095/ubitx_35B7.tft

Cheers,
The Groups.io Team

New file uploaded to BITX20@groups.io

BITX20@groups.io Notification <BITX20+notification@...>
 

Hello,

This email message is a notification to let you know that a file has been uploaded to the Files area of the BITX20@groups.io group.

File: ubitx_35E7.HMI

Uploaded By: Allen Merrell

Description:

You can access this file at the URL:
https://groups.io/g/BITX20/files/3.2%20&%203.5%20for%20Nextion%20and%20CEC%201.095/ubitx_35E7.HMI

Cheers,
The Groups.io Team

New file uploaded to BITX20@groups.io

BITX20@groups.io Notification <BITX20+notification@...>
 

Hello,

This email message is a notification to let you know that a file has been uploaded to the Files area of the BITX20@groups.io group.

File: ubitx_35E7.tft

Uploaded By: Allen Merrell

Description:

You can access this file at the URL:
https://groups.io/g/BITX20/files/3.2%20&%203.5%20for%20Nextion%20and%20CEC%201.095/ubitx_35E7.tft

Cheers,
The Groups.io Team

Re: New file uploaded to BITX20@groups.io

Allen Merrell
 

Michel, I made some changes in the scale on the s meter, give it a try and let me know how it works. 
Thanks for testing.
kn4ud
--
Allen  Merrell

Re: 3.2in Nextion display now looks great.

Allen Merrell
 

Malcolm, you have your rig looking very good. I like your case design. 
kn4ud
--
Allen  Merrell

Re: Finding variables in source code

W2CTX
 

IDE "find" is really handy but it only searches the currently opened file.  The old

"grep" command can search many files.


ron

On July 16, 2018 at 5:21 PM Arv Evans <arvid.evans@...> wrote:

The Arduino IDE, and most other IDEs include "find" and "find next"  in the edit commands.
This is very similar to the now ancient UNIX grep, fgrep, etc that eventually made its way into
several DOS editors.  Linux has continued the grep legacy in original and several new forms.
Not sure but I would think that Apple's OSX would also include the function as it was there in
original BSD UNIX.  It is also present in the shell programming tool for my Linux based
Android cell phone.

Us real old timers might use use SED (stream editor)to find and change specific words in
one pass.  This is handy for changing all occurrences of a word in the whole document.

Arv K7HKL
_._

On Mon, Jul 16, 2018 at 3:07 PM AA9GG < paul.aa9gg@...> wrote:
I remember GREP from the old DOS days.  Most editors for programming have a search feature. One could also load the code into a text editor and use its search function.  


Virus-free. www.avast.com

On Sun, Jul 15, 2018 at 11:22 AM, Jack Purdum via Groups.Io <jjpurdum@...> wrote:
 
I think we all run into situations where we need to find the definition of a variable or object in a large set of files. The UNIX tool Grep is perfect for doing that. The Grep version I use is not longer available, but I just downloaded and tried this version and it seems to work well:



If you want to change the data type of a variable, use Grep and type in the variable name, supply a search path, and BINGO it finds all occurrences of that string in the directory/subdirectories seach.

Jack, W8TEE



On Sunday, July 15, 2018, 11:06:15 AM EDT, Lee < mr.olson@...> wrote:


Thanks Mike,  I did not know about General coverage mode.  It seems to step buy .1MHZ  which is what I was trying to do.  Thanks to the others for the WWV ideas but my reference to WWV was an example. 

My changes work as I wanted but I still would like to figure out how to make it display correctly.  I cannot find where to change the data type to unsigned long.
--
Lee - N9LO  "I Void Warranties"

 

 

 




--
Paul Mateer, AA9GG
Elan Engineering Corp.
www.elanengr.com
NAQCC 3123, SKCC 4628

 

 

Re: Finding variables in source code

Jack Purdum
 

True, Ron, and that's were Grep shines over most editors, since they are usually limited to the current file. Grep not only searches all of the files in the current directory, it also search all of the subfolders of the current directory. Often that "deep search" is exactly what's needed.

Jack, W8TEE

On Monday, July 16, 2018, 6:52:27 PM EDT, W2CTX <w2ctx@...> wrote:


IDE "find" is really handy but it only searches the currently opened file.  The old

"grep" command can search many files.


ron

On July 16, 2018 at 5:21 PM Arv Evans <arvid.evans@...> wrote:

The Arduino IDE, and most other IDEs include "find" and "find next"  in the edit commands.
This is very similar to the now ancient UNIX grep, fgrep, etc that eventually made its way into
several DOS editors.  Linux has continued the grep legacy in original and several new forms.
Not sure but I would think that Apple's OSX would also include the function as it was there in
original BSD UNIX.  It is also present in the shell programming tool for my Linux based
Android cell phone.

Us real old timers might use use SED (stream editor)to find and change specific words in
one pass.  This is handy for changing all occurrences of a word in the whole document.

Arv K7HKL
_._

On Mon, Jul 16, 2018 at 3:07 PM AA9GG < paul.aa9gg@...> wrote:
I remember GREP from the old DOS days.  Most editors for programming have a search feature. One could also load the code into a text editor and use its search function.  


Virus-free. www.avast.com

On Sun, Jul 15, 2018 at 11:22 AM, Jack Purdum via Groups.Io <jjpurdum@...> wrote:
 
I think we all run into situations where we need to find the definition of a variable or object in a large set of files. The UNIX tool Grep is perfect for doing that. The Grep version I use is not longer available, but I just downloaded and tried this version and it seems to work well:



If you want to change the data type of a variable, use Grep and type in the variable name, supply a search path, and BINGO it finds all occurrences of that string in the directory/subdirectories seach.

Jack, W8TEE



On Sunday, July 15, 2018, 11:06:15 AM EDT, Lee < mr.olson@...> wrote:


Thanks Mike,  I did not know about General coverage mode.  It seems to step buy .1MHZ  which is what I was trying to do.  Thanks to the others for the WWV ideas but my reference to WWV was an example. 

My changes work as I wanted but I still would like to figure out how to make it display correctly.  I cannot find where to change the data type to unsigned long.
--
Lee - N9LO  "I Void Warranties"

 

 

 




--
Paul Mateer, AA9GG
Elan Engineering Corp.
www.elanengr.com
NAQCC 3123, SKCC 4628

 

 

Re: Mike element

iz oos
 

So, would - 24db be 20db more sensitive than - 44db?


Il 16/lug/2018 22:26, "k1yw via Groups.Io" <k1yw=mail.ru@groups.io> ha scritto:
0 dB = 1 volt per Pascal
-24dB = .0.063 V/Pa
-44 db = 0.0063 V/Pa

Re: Mike element

Jerry Gaffke
 

Yes, you have it right.

For a given sound pressure into the mike,
the -24 dB mike creates a voltage that is 10 times bigger than the -44 dB mike.
A 10 times bigger voltage into a fixed resistance means 100 times more power,
since power in watts = volts * amps =   volts * volts/ohms.
With 100 times more power, that's 10 * log(100) = 20 dB more power.

If the mike were zero dB, we'd get 1 volt from the mike.
Since the voltages we are dealing with are less than one volt, 
we get negative numbers when representing the values in dB.

Jerry, KE7ER


On Mon, Jul 16, 2018 at 04:58 PM, iz oos wrote:

So, would - 24db be 20db more sensitive than - 44db?


Il 16/lug/2018 22:26, "k1yw via Groups.Io" <k1yw=mail.ru@groups.io> ha scritto:
. . .

 

0 dB = 1 volt per Pascal
-24dB = .0.063 V/Pa
-44 db = 0.0063 V/Pa

Re: Mike element

Gordon Gibby
 

With that level of sensitivity, perhaps no preamp at all is needed with the bitx  series.

Available for three dollars at digikey. 

Thanks for pointing it out and giving that educational lecture!


On Jul 16, 2018, at 21:51, Jerry Gaffke via Groups.Io <jgaffke@...> wrote:

Yes, you have it right.

For a given sound pressure into the mike,
the -24 dB mike creates a voltage that is 10 times bigger than the -44 dB mike.
A 10 times bigger voltage into a fixed resistance means 100 times more power,
since power in watts = volts * amps =   volts * volts/ohms.
With 100 times more power, that's 10 * log(100) = 20 dB more power.

If the mike were zero dB, we'd get 1 volt from the mike.
Since the voltages we are dealing with are less than one volt, 
we get negative numbers when representing the values in dB.

Jerry, KE7ER


On Mon, Jul 16, 2018 at 04:58 PM, iz oos wrote:

So, would - 24db be 20db more sensitive than - 44db?


Il 16/lug/2018 22:26, "k1yw via Groups.Io" <k1yw=mail.ru@groups.io> ha scritto:
. . .

 

0 dB = 1 volt per Pascal
-24dB = .0.063 V/Pa
-44 db = 0.0063 V/Pa

Re: Finding variables in source code

Jon Titus, KZ1G <tituskz1g@...>
 

The problem with how to locate variables also involves how programmers label them.  Too many books, teachers, and hobbyists use nonsense variables such as i, j, index, ptr, and so on as variable names.  Use variable names that indicate how you use them--Keyboard_Input, XMIT_Switch_State--and you save yourself and others endless searches and wasted time.
--
Jon Titus, KZ1G
Herriman, UT USA

Re: Windows Serial Port Problem

Jon Titus, KZ1G <tituskz1g@...>
 

Counterfeit boards bear marks that make them look like Arduino.cc-produced boards.  (Much like counterfeit watches marked as "Rolex.")  People can get tricked into buying boards with a USB, or other chip, that makes them compatible only after they download special drivers, etc.  If a company produces an Arduino clone they should mark it as such.  They also should note that a given board is compatible with an Arduino XXX, but is a product not of Arduino.cc but of another company.  Be careful what you buy and read the specifications carefully.  Just my opinion from experiences with Arduino boards.
--
Jon Titus, KZ1G
Herriman, UT USA

Re: Finding variables in source code

Jack Purdum
 

It depends. I use i, j, and index quite often in my code and find nothing wrong with it because those variables are almost always used for the same purpose and are rarely the source of program bugs. Everyone has their own coding style...unless you work as a programmer where style is dictated. Personally, I never use an underscore in a variable name for two reasons: 1) double-underscores were typically used as system variables and I still think that when I see them (it's a personal problem), and 2) while I can probably type 70wpm, the underscore key slows me down because I rarely use it. Some coding conventions I've found useful:

    1. Start variable names with a lowercase letter, and only cap the first letter of sub-words: keyboardInput, xmitSwitchState, ptrSisters.
    2. Start function names with an uppercase letter. That way you can tell in a glance whether it's a variable or a function. That's especially useful when you use pointer to         functions.
    3. Variables are like nouns in a sentence. Typically they reflect something of interest in the program and the name should convey that.
    4. Make the name long enough to convey that interest, but short enough you don't find it burdensome to type it over and over.
    5. Function are like verbs in a sentence. Typically they reflect an action taken and the function name should reflect the action, but not the means of the action. That is,         SortList() is a better name than BubbleSortList() because the former says what's to be done, while the latter says what's to be done and here's how I'm going to do it.
        a. Functions are black boxes with no windows. It's nobody else's business what goes on inside. What happens in functions stays in functions. Do you really want to force             users to recode their programs because you stopped using a Bubble Sort and switched to a Shell Sort? Hint: NO.
    6. Make functions cohesive. It you cannot say what a function does in two sentences, it's probably trying to do too many things. Break it into two smaller, and probably more         reusable, functions. Beginning students too often try to write Swiss Army Knife functions; they do a lot, but nothing well. Rarely is a function with a long parameter list a         cohesive function. Passing in flag variables is a dead giveaway that you're trying to make the function do too many things.
    7. Learn how to read and use complex data definitions. For example, what does this definition define:

                double (*(*pf)())[3][4];

        It's easier than you think to figure this out using the Right-Left Rule. (See:http://jdurrett.ba.ttu.edu/3345/handouts/RL-rule.html) Because C allows you to "create" new data types, it's an extremely robust and power language.

Writing C code is a personal thing and everyone is free to write it anyway they want as long as the compiler can parse it. However, when you know someone else has to read it, clarity starts to gain importance and style plays a part, too.

Jack, W8TEE

On Monday, July 16, 2018, 11:13:12 PM EDT, Jon Titus, KZ1G <tituskz1g@...> wrote:


The problem with how to locate variables also involves how programmers label them.  Too many books, teachers, and hobbyists use nonsense variables such as i, j, index, ptr, and so on as variable names.  Use variable names that indicate how you use them--Keyboard_Input, XMIT_Switch_State--and you save yourself and others endless searches and wasted time.
--
Jon Titus, KZ1G
Herriman, UT USA

Re: New file uploaded to BITX20@groups.io

Michel Dupuy
 

Hi Merrell, I tried the ubitx_35B7.tft version and there is always the problem. I solved it by modifying the code: (replace 10 by 12)


//Draw Smeter

  if(pm.cp.val!=-1)

  {

    jSMeter.val=pm.cp.val*12  <—— 10

    pm.cp.val=-1


It works fine, I do not know if it's the right solution because I'm not an expert.
That's why and thank you.

Michel F1GTXLe 17 juil. 2018 à 00:05, Allen Merrell via Groups.Io <kn4ud@...> a écrit :

Michel, I made some changes in the scale on the s meter, give it a try and let me know how it works. 
Thanks for testing.
kn4ud
--
Allen  Merrell

Re: HDMI display

Tom, wb6b
 

I agree that taking advantage of the CAT interface and using a second computer, that is HDMI capable, is probably the most practical approach. 

However:

One big advantage of the Arduino computers is they make writing programs interacting I/O pins possible in an easy and understandable way. 

I stumbled upon this library that brings the same type of I/O programming simplicity to the Raspberry Pi. http://wiringpi.com

Assuming a Raspberry Pi Zero (which has an HDMI output) is not too big of an RF noise factory, one could replace the Nano with the Pi Zero.

For hacking something like this together, rather than remove the Nano from the Raduino board, you could reprogram the Raduino to be an I2C to LCD display adaptor and drive the LCD display (assuming you may like to have an LCD display in addition to an HDMI display) and the Si5351 chip from the Rpi over the I2C bus. Then connect I/O pins from the Rpi, as needed, to the back of the Raduino to let the Rpi directly take over the I/O functionally that was handled by the Nano when it was running the uBITX firmware.

Tom, wb6b

Re: Windows Serial Port Problem

m5fra2@...
 

But they are not counterfeit as the hardware and software is open source.

 

 

From: BITX20@groups.io <BITX20@groups.io> On Behalf Of Jon Titus, KZ1G
Sent: 17 July 2018 04:20
To: BITX20@groups.io
Subject: Re: [BITX20] Windows Serial Port Problem

 

Counterfeit boards bear marks that make them look like Arduino.cc-produced boards.  (Much like counterfeit watches marked as "Rolex.")  People can get tricked into buying boards with a USB, or other chip, that makes them compatible only after they download special drivers, etc.  If a company produces an Arduino clone they should mark it as such.  They also should note that a given board is compatible with an Arduino XXX, but is a product not of Arduino.cc but of another company.  Be careful what you buy and read the specifications carefully.  Just my opinion from experiences with Arduino boards.
--
Jon Titus, KZ1G
Herriman, UT USA


Virus-free. www.avast.com