Go to advanced search

by Grumpy Mike
Sun Aug 29, 2021 10:18 am
Forum: The MagPi
Topic: Hex Keys - Part 2 MagPi#109 Figure 3
Replies: 1
Views: 758

Hex Keys - Part 2 MagPi#109 Figure 3

MagPi# 109, page 60 Figure 3.

I see the published figure has been laid out so the edges have been cut off, therefore I have placed a copy of the original PDF for Figure 3 in the GitHub folder for Hex Keys part 2.

Mike Cook
by Grumpy Mike
Mon Aug 02, 2021 10:41 am
Forum: SDK
Topic: Help in understanding the C in the sine_i2s example
Replies: 4
Views: 331

Re: Help in understanding the C in the sine_i2s example

Thank you, I have never had the need to pass a structure to a function, I will try this. Yes it works, for others who might be following this I called the function with:- produceNote(ap); and defined the function as:- void produceNote(struct audio_buffer_pool *ap) Thanks again, never stop learning d...
by Grumpy Mike
Mon Aug 02, 2021 10:39 am
Forum: SDK
Topic: Help in understanding the C in the sine_i2s example
Replies: 4
Views: 331

Re: Help in understanding the C in the sine_i2s example

That line is the variable declaration. It is a variable called ap that is a pointer to an audio_buffer_pool struct. OK thanks. But to use it in another function I would have to know the data type in order to pass it on to that function. So what is the data type I use in the function that is going t...
by Grumpy Mike
Mon Aug 02, 2021 10:29 am
Forum: SDK
Topic: Help in understanding the C in the sine_i2s example
Replies: 4
Views: 331

Help in understanding the C in the sine_i2s example

I am playing about with the sine_i2s example and there is something I don't understand about the C used. In the main function there is a line struct audio_buffer_pool *ap = init_audio(); Which I understand is to make an instance of a structure and store in the variable "ap". However the va...
by Grumpy Mike
Sat Jul 10, 2021 1:53 pm
Forum: The MagPi
Topic: Software used for stripboard/perfboard diagrams
Replies: 10
Views: 2322

Re: Software used for stripboard/perfboard diagrams

I noticed a few little layout tricks in your diagrams which have come in handy when routing stripboards. Good, although I have been laying out stuff for years now that, what ever they are, I don't really consider them to be tricks, but just what comes natural. Basically I have this attitude that th...
by Grumpy Mike
Fri Jul 09, 2021 9:49 am
Forum: The MagPi
Topic: Software used for stripboard/perfboard diagrams
Replies: 10
Views: 2322

Re: Software used for stripboard/perfboard diagrams

Could anybody tell me what software is used for the stripboard/perfboard diagrams, esp. for Mike Cook's articles? I use MacDraft P.E. We are up to version 7.0.3 now. In the very early days I used MacDraw and changed over to MacDraft when apple abandon MacDraw. It is just a general purpose 2D drawin...
by Grumpy Mike
Mon Jun 28, 2021 3:39 am
Forum: SDK
Topic: OLED driver in C? [Solved]
Replies: 12
Views: 1247

Re: OLED driver in C? [Solved]

OK solved now.
The code accompanies my MagPi article in the https://magpi.raspberrypi.org/issues/107 Pico-Voice changer Part 2
You can find it at http://magpi.cc/pibakery .
Many thanks to @martinkooij for sorting it out.

Video for the project at https://www.youtube.com/watch?v=4Wi9soy2nGQ
by Grumpy Mike
Sun Jun 13, 2021 9:00 pm
Forum: SDK
Topic: [solved] Pico GPIO interrupts
Replies: 5
Views: 2431

Re: [solved] Pico GPIO interrupts

This is the link to interrupts in MicroPython. They are called "call backs"
https://docs.micropython.org/en/latest/ ... witch.html
by Grumpy Mike
Thu May 13, 2021 5:56 pm
Forum: General discussion
Topic: LXTerminal stopped scrolling
Replies: 4
Views: 288

Re: LXTerminal stopped scrolling

Thanks Guys, There is a "Scroll-back lines" setting in Edit → Preferences → Display, and setting that to zero would give the behaviour. Yes it was but didn't fix it on its own. tput rmcup Didn't seem to do much except send the cursor to the top of the screen. The reset command should also ...
by Grumpy Mike
Thu May 13, 2021 5:57 am
Forum: General discussion
Topic: LXTerminal stopped scrolling
Replies: 4
Views: 288

LXTerminal stopped scrolling

Something has happened on my Raspberry Pi 400, the LXTerminal seems to have lost its ability to scroll. What ever window size I choose is just how ever many lines I get. The side scroll bar is the height of the window. It used to work normally but it doesn't now. I did change some colour settings bu...
by Grumpy Mike
Thu May 06, 2021 1:24 pm
Forum: SDK
Topic: OLED driver in C? [Solved]
Replies: 12
Views: 1247

Re: OLED driver in C?

martinkooij wrote:
Thu Apr 29, 2021 8:30 pm
No problem. Can you provide a pointer to yor code? Github, pastebin, zip attachment,... ? C files, header files, CMakeLists.txt..
Sure can you contact me with a PM and I will send you a link.
by Grumpy Mike
Thu Apr 29, 2021 2:14 pm
Forum: SDK
Topic: OLED driver in C? [Solved]
Replies: 12
Views: 1247

Re: OLED driver in C?

A great big thanks for your contribution. I was able to run the demo code and confirm that my hardware was working. All I had to do was to change the I2C address I had wired it up to. So instead of the C pattern where you would create a struct holding some specific data to the oled and pass the addr...
by Grumpy Mike
Thu Apr 29, 2021 6:54 am
Forum: SDK
Topic: OLED driver in C? [Solved]
Replies: 12
Views: 1247

Re: OLED driver in C?

The filenames look like they've been renamed to cpp and ino so they'll work with Arduino, but I don't see anything that looks like C++ Well in the file ss_oled.hpp there is class picoSSOLED { Which is very C++ ;) Thanks ConfuSomu for that other link, I will try and get this compiled. On a related n...
by Grumpy Mike
Wed Apr 28, 2021 7:54 pm
Forum: SDK
Topic: OLED driver in C? [Solved]
Replies: 12
Views: 1247

Re: OLED driver in C?

Thanks Guys,
are you looking for an SSD1306 driver
Yes.
I did copy that link from a read me file, and on closer examination I got two - before the last word, sorry.
This is what I tried:-
https://github.com/martinkooij/pi-pico-ss-oled
by Grumpy Mike
Wed Apr 28, 2021 4:32 pm
Forum: SDK
Topic: OLED driver in C? [Solved]
Replies: 12
Views: 1247

OLED driver in C? [Solved]

I want to incorporate an OLED display in a C project. I have found one at:- https://github.com/martinkooij/pi-pico-ss--oled It uses the Pico's I2C drivers but it is for C++. Any Idea how to use this with C code, or how to remove the C++ wrapper? Or indeed another OLED driver that will work with the ...
by Grumpy Mike
Wed Apr 21, 2021 9:02 am
Forum: SDK
Topic: [solved] Pico GPIO interrupts
Replies: 5
Views: 2431

Re: Pico GPIO interrupts

You might easily get a couple of edges within less than a microsecond. Your interrupt handling might be taking too long. I don't see how that should be a problem. An interrupt gets triggered and at the same time an interrupt enable bit somewhere in the processor is cleared. Then for the length of t...
by Grumpy Mike
Tue Apr 20, 2021 11:46 am
Forum: SDK
Topic: [solved] Pico GPIO interrupts
Replies: 5
Views: 2431

Re: Pico GPIO interrupts

Yes it is mechanical, I slugged it with a 0.1uF ceramic, signals look as clean as a whistle but still I get some readings showing both up and down states.
by Grumpy Mike
Tue Apr 20, 2021 9:46 am
Forum: SDK
Topic: [solved] Pico GPIO interrupts
Replies: 5
Views: 2431

[solved] Pico GPIO interrupts

I am trying to implement a rotary encoder interface using GPIO interrupts. As there is only one vector for all GPIO interrupts and I want some single buttons as well, then in the interrupt handling function I look at what pin has caused the interrupt and pass the call to the appropriate function. Al...
by Grumpy Mike
Sat Apr 17, 2021 8:01 pm
Forum: General
Topic: Arduino has released a Pico programming soloution
Replies: 13
Views: 1179

Re: Arduino has released a Pico programming soloution

Well bless your heart! Will patronising me put me in a better mood? Some home truths. The point is that the Raspberry Pi foundation, or at least those job it is to write the software to access this chip, think they have done a good job, and they don't care if if people don't like it. They said so i...
by Grumpy Mike
Fri Apr 16, 2021 9:47 pm
Forum: General
Topic: Arduino has released a Pico programming soloution
Replies: 13
Views: 1179

Re: Arduino has released a Pico programming soloution

It doesn't sound like that functionality is a priority: it's a whole new thing for the Wiring/Arduino language.
I suppose so, in the same way that ease of use is not a priority from the Raspberry Pi foundation.
by Grumpy Mike
Fri Apr 16, 2021 5:20 am
Forum: General
Topic: Arduino has released a Pico programming soloution
Replies: 13
Views: 1179

Re: Arduino has released a Pico programming soloution

Thing is that Arduino support is still in its infancy. From what I can see it has not yet implemented anything to do with PIO yet. It works with the original Raspberry Pi Pico. But I run in a trap with Servo. Servo will not work for me. Not a surprise because the servo library depends on the specifi...
by Grumpy Mike
Wed Apr 14, 2021 9:10 pm
Forum: General
Topic: Arduino has released a Pico programming soloution
Replies: 13
Views: 1179

Arduino has released a Pico programming soloution

Just received this from the Arduino Forum:- The Arduino IDE and CLI now have support for the Pico and the Nano RP2040 Connect! This was developed by the Arduino team and is available for free for anyone. Just open the Board Manager dialog and look for their names: you’ll find the two new cores. If y...
by Grumpy Mike
Sun Apr 04, 2021 4:28 am
Forum: General
Topic: Trying to use I2S example
Replies: 22
Views: 1398

Re: Trying to use I2S example

Thanks hippy, your reply - 31 Mar 2021 17:58 worked very well for me. For the sake of anyone wanting to know the answer this is it. To make it work on the Pimoroni pico audio board you have to change the sin_wave.c ( or what ever you call it) to read:- struct audio_i2s_config config = { // for Pimor...
by Grumpy Mike
Tue Mar 30, 2021 6:45 am
Forum: General
Topic: Trying to use I2S example
Replies: 22
Views: 1398

Re: Trying to use I2S example

Thank you for your reply. However, I am not sure about some things. you should rename pico_playground to the name of your project I do think that is not a long term solution, eventually I would like to share my work as open source example. As I see it tying things to the way you have installed Pico ...
by Grumpy Mike
Sun Mar 28, 2021 6:17 pm
Forum: General
Topic: convert an arduino project for a pico
Replies: 3
Views: 429

Re: convert an arduino project for a pico

it told me the neopixel did not like the interrupts They don't because in an Arduino the interrupts have to be turned off to get the timing correct. luckily with the Pico you can program the PIO state machine to do the refreshing automatically, taking zero CPU time. There is an example of this in t...

Go to advanced search