Code Monkey home page Code Monkey logo

alice's People

Contributors

jacroe avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

Forkers

rosshettel

alice's Issues

Create new events/macros module

Events are like macros. It's a list of several things to do and can be called with one function call.

It's like a cross between modules and recipes.

API Rate limiting

WUnderground and the Rotten Tomatoes APIs need rate limiting. Probably add another variable to data.php and then reset it to zero after 2300 using an if in cron.php.

Also need to work out where and when to cut back on lookups.

Meta page

In thinking of how to add #32, there really isn't a good area to say when something is online/offline/up/down/etc. besides adding an item to the errors[] array. Except that's really to be used only for somewhat pressing matters. E.g., we don't say we couldn't update Alice's data until an arbitrary number of minutes (20); it's not that pressing until then.

So perhaps a meta/status page is warranted. We could add a running list of errors from error.log, perhaps an event log file, and be able to display the status of objects.

[Email] alice_email_getAllMessages() doesn't always return an HTML body

The reason why PHP doesn't actually list the sections available in imap_fetchbody() is because they vary from message to message. What may give HTML in one message may return NULL in another. Fix this by writing a recursive function to find which part is HTML and which part is PLAIN (this way, if there isn't HTML we can at least give PLAIN). Will use imap_fetchstructure().

Examples of different sections by different providers:

1   - Redbox html, Simple txt, Amazon both
1.1 - Redbox none, Simple none, Amazon txt
1.2 - Redbox none, Simple none, Amazon html
2   - Redbox none, Simple html, Amazon none

Nota bene There is no x.0.

[API] Check for arrays of calls

Check for an array of calls when processing them? This will allow our events (#37) to work easier barely changing existing calls, if at all.

Groceries and shopping lists

Build a database of items I keep and know what I need when I go shopping plus an estimated price.

While we could use existing database structures, I believe this warrants a new table and schema. Should store reference id, name (should this be "Head and Shoulders" or "shampoo"?), section ("Health"), aisle number ("7"), price, and if we need it ("true").

This should also include a way of getting it to me, whether that's through an email or however. Should be sorted in the order I would pick it up and give me an estimated cost.

  • Mark items as needed/unneeded from web interface
  • Add items from web interface (even if it simply adds "eggs" and nothing else)
  • Optional Design the printed page

Implement a notification system

This is different than what was at #11; that one would have been an action system whereas this will be a displaying of actions taken by other programs on the computer.

Basically, expand the API to allow other programs to ping it with data and somehow display a running list, probably on the home page. For example, notifications that Deluge finished downloading a file or that Sickbeard was updated.

Running list of items that will probably use this

  1. Sickbeard and updates
  2. Deluge
  3. Email sorting (for specific pieces of it, such as Amazon shipment or bank transfer)

X10 On button doesn't disable Brighten

On is only enabled when the device is fully off. And when On is pushed, the device is fully on. So Brighten should be disabled.

Likewise, pushing Off doesn't re-enable Brighten.

Design the Home section

To be included

  • Latest webcam image
  • Information about X10 devices and the ability to control them
  • Time until the next event(s) occur. Ex. 30 minutes until the bedroom lamp turns on

Replace Pushover module with Notify

Replace the current Pushover module with a Notify module. This will be where we send out notifications by email. Pushover, or through the web interface (TBD how later). Something like:

function alice_notify(string $title, string $message, array $services)
#Services:
function alice_pushover(string $title, string $message)
function alice_notificationEmail(string $subject, string $body)
function alice_notificationWeb(string $subject, string $message)

Then using those listed in $services, make calls to each function.

(Hopefully what I'm trying to say will make sense later when I actually implement this.)

Can't purge upon fresh install

Because the variable "update_time" isn't in the a_modules database, there is no link to purge the data. Add the value to the initial alice.sql

Store/cache images

Weather images should all be stored someplace. Either in the database (which calls for a new table and means new schema and noncompliance with current mysql functions) or in a directory someplace.

Internet connection not down if it was a minute

Change the connection down recipe to only notify me if it was longer than a minute. What may be happening is that a request is being considered down when it just timed out that one time.

Change error reporting to accept multiple errors

Pass an array on to Smarty and use it to display all errors in that array. Errors are issues with Alice and her ability to either connect with a program (such as with XBMC now) or that she hasn't been updated in x minutes or etc.

Errors are not notifications about problems that other programs are having, such as SABnzbd's quota has been filled. Those will go into a notification area (where there will be priorities).

Timer recipe

Probably will be a module. Will store time() it should go off as a database variable named timer_TimerName. Then cron the check.

PHP's call_user_func might be useful if we want to give an option as how to notify the job is finished.
#29 will be required before this can be completed.

Add "Play Next Episode" button

When pressed, will play the next unwatched episode of a tv show. If I ever get around to implementing a database, we can change this to watch the episode following the one last watched.

Have better X10 support

Right now X10 support is almost non-existent. It's all hard-coded commands. Flesh it out to easily

  1. Allow adding modules (first from text files/databases and then from the web interface)
  2. Naming them (bedroom lamp)
  3. Storing the current state (on, off, dimmed 5)

I see the modules to be stored in a new database with schema Name, Device code, Device type, Current state

Add Deluge module

Add Deluge torrent support. (I'm digging Deluge more than I am with Transmission, and since this is still personal project...)

Leave both modules in with Alice and include new variable in alice.sample.php that will define which to use.

[Timer] Displaying timers

Display a list of the current timers, their messages, and how much time is remaining for each one.

  • New function that returns time remaining (Could use alice_timeDiff())
  • Placement in template

Insert mysql variables

Currently, any variable to be stored in the database must already exist. Check for the non existence of the variable and INSERT it.

[Weather] When does "Today" end?

See if WUnderground's API page tells when "Today"'s forecast ends and "Tonight's" forecast begins. And same with "Tonight" and "Tomorrow".

[XBMC] Rewrite

The XBMC module right now is clunky, ugly, and slow. Rewrite it.

[API] Return data

Give some data back in the form of JSON

  • XBMC Films
  • XBMC TV shows
  • XBMC Control
  • X10
  • Timer
  • Notifications
  • Groceries

[Email] Rewrite email purge recipe

To make this more useful, let's actually not determine if we should do something in the function. Rather, let's ask the module to return emails in an array based on given rules (e.g., a certain subject line, a from address, etc.). Then we can call other functions such as mail_delete($mailID) or mail_move($mailID).

Also see about using a reference variable to the connection so we don't have to recreate it after each return. We can create a mail_connect() function and then return the connection. Although, I really dislike having functions that just connect. Function already exists.

Rotten Tomatoes integration

Display the Tomatometer rating and the blurb using RT API when viewing a movie.

Could decide to later not do this; idea is if you own it already, you must think somewhat highly of it.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.