Read the statement by Michael Teeuw here.
Module to display information from a text file on a locally shared folder
-
I am looking for some type of way to display information from a text file that is saved to a local network share.
We have six year old twins who are starting second grade. I am looking for a way to have a list of “sight words” (common words they are learning) displayed on the screen where the default newsfeed is at. I could edit the compliments list but I would rather have a module that would pull the words from a text file that is saved to a local network share so that I can update it as needed. The words could rotate after a set time period.
Is there any current module that is capable of this? If not, would anyone be willing work on one? I am nto a programmer and have no idea where to even start with creating something like this.
Thanks.
-
@TomBrown compliments can read from a file, and u can link that file to be on a file server.
and u can run two instances of compliments showing different info.
only issue is that it reads the file only on startup.
-
Sam,
Thanks for the reply! I will have to read up on configuring that module then and figure out how to link to a file. Reading it only on startup is alright as I could restart daily or weekly. -
@TomBrown see the ln command for link
the compliments file MUST be in the compliments folder or subfolder. it cannot just be anywhere
the module config entry is
remoteFile: 'my_comp.json',
so, you could make a link like this
ln -s my_comp.json /mount_location/path/filename.xxx
that means make a file entry in the current folder called my_comp.json
and map it to the mounted file filename.xxxi use this approach for linking pictures from my file server to be shown by the MMM-ImagesPhotos module
-
@sdetweil said in Module to display information from a text file on a locally shared folder:
@TomBrown see the ln command for link
the compliments file MUST be in the compliments folder or subfolder. it cannot just be anywhere
the module config entry is
remoteFile: 'my_comp.json',
so, you could make a link like this
ln -s my_comp.json /mount_location/path/filename.xxx
that means make a file entry in the current folder called my_comp.json
and map it to the mounted file filename.xxxi use this approach for linking pictures from my file server to be shown by the MMM-ImagesPhotos module
I have not tried any of this yet (have not had the time yet) but trying to make sure I understand.
If I created the word list file called “wordlist.txt”, saved that file to a share of “\server\share\wordlist.txt”.
I would create a file named “my_comp.json” in the compliments folder.
Then link it to the text file withln -s my_comp.json /server/share/wordlist.txt
And the wordlist.txt would look something like this.
{ "anytime" : [ "Band", "Firetruck", "Movie", ], "morning" : [ "Good morning, sunshine!", ], "afternoon" : [ "Hitting your stride!", ], "evening" : [ "See you tomorrow!", ], }
Or would it be easier all around to just set the “remotefile:” and save it locally on the pi. I will be connecting to the pi over vnc.
-
@TomBrown the ln command ‘creates’ the local file.
and the file can contain just words in each of the time slots.make it work with an actual file, and then see if that is what u want. if so, then you can move the real file to the server. mount the drive into the pi, and then link the local file to the server file
-
OK. Just an update. Finally got back to this. Have it installed and mounted. Kids like it!
-
@TomBrown cool, thx for the feedback
is the file on the.pi, or on a server like u had originally wanted?
-
@sdetweil Right now the file is on the pi. This has been on hold since I originally posted as other things came up.
-
@TomBrown no. just interested… good work